home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
kermit.columbia.edu
/
kermit.columbia.edu.tar
/
kermit.columbia.edu
/
newsgroups
/
misc.20021006-20030409
/
000270_fdc@columbia.edu_Sun Feb 9 16:46:00 EST 2003.msg
< prev
next >
Wrap
Text File
|
2003-04-08
|
2KB
|
61 lines
Article: 14064 of comp.protocols.kermit.misc
Path: newsmaster.cc.columbia.edu!news.columbia.edu!news-not-for-mail
From: fdc@columbia.edu (Frank da Cruz)
Newsgroups: comp.protocols.kermit.misc
Subject: Re: input pattern matching blowing my mind...
Date: 9 Feb 2003 16:45:47 -0500
Organization: Columbia University
Lines: 44
Message-ID: <b26i6b$iiv$1@watsol.cc.columbia.edu>
References: <uisvwssje.fsf@att.net> <b213u0$i95$1@watsol.cc.columbia.edu> <u8ywrd5o8.fsf@att.net>
NNTP-Posting-Host: watsol.cc.columbia.edu
X-Trace: newsmaster.cc.columbia.edu 1044827148 2505 128.59.39.139 (9 Feb 2003 21:45:48 GMT)
X-Complaints-To: postmaster@columbia.edu
NNTP-Posting-Date: 9 Feb 2003 21:45:48 GMT
Xref: newsmaster.cc.columbia.edu comp.protocols.kermit.misc:14064
In article <u8ywrd5o8.fsf@att.net>,
Thomas A. Horsley <tom.horsley@att.net> wrote:
: >It seems to happen only in \fpattern() arguments, and only when SET INPUT
: >CASE is OFF.
:
I should have said CASE ON but you figured it out...
: Thanks! That works for me, but I have even more confusing results
: now. Here is the script in its current form (which works):
: ...
: If I try to move everything into the while loop:
:
: output \13
: input 10 {linux> }
: if success {
: output ssh-add\13
: while 1 {
: set input case observe
: minput 10 {try again: } {linux> } \Fpattern({Enter passphrase for*:?})
: if failure { break }
: if = \v(minput) 2 { break }
: askq /GUI \%p \v(inmatch)
: output \%p\13
: }
: }
: connect
:
: It (once again) never matches the initial prompt. I can't even get
: it to work in this case by leaving off the "E" :-).
:
Whatever the problem is, it's the same one. As noted on page 458 of Using
C-Kermit, a few commands including SET [ INPUT ] CASE are on the call stack.
The braces around the WHILE statement's command list push a new context
onto the stack.
Anyway there's no reason to put the SET INPUT CASE command inside the
WHILE loop since it only needs to be executed once, and the setting is
inherited when you start a new stack level.
I still haven't had a chance to look at the source code, but let me just
ask if it makes a difference if you remove the braces from around the
\finput() argument, since they should be superfluous in this case.
- Frank